﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Windows.Forms;
namespace WindowAPI
{
    public class Clipboard
    {


        public static void SetWords(string words)
        {
            System.Windows.Forms.Clipboard.SetDataObject(words);
        }

        public static string GetWords()
        {
            IDataObject data = System.Windows.Forms.Clipboard.GetDataObject();
            if (data.GetDataPresent(System.Windows.Forms.DataFormats.Text))
            {
                return (string)data.GetData(System.Windows.Forms.DataFormats.Text);
            }
            else
            {
                return "";
            }
        }
    }
}
